<%--
  Created by IntelliJ IDEA.
  User: bonoh
  Date: 2023/10/25
  Time: 13:44
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>日期时间显示</title>
</head>
<body>
<h3>日期时间显示</h3>
<%@ page import="java.util.Date" %>
<%@ page import="java.text.SimpleDateFormat" %>
<%
    Date data = new Date();//获取系统当前日期
    out.println("Date对象对应的日期为："+data+"<br/>");
    out.println("当前时间为："+new SimpleDateFormat("HH:mm:ss").format(data)+"<br/>");
%>

</body>
</html>